#ifndef GAMELITEM_H
#define GAMELITEM_H

#include <QFrame>
#include <QMenu>
#include "datamodel.h"

namespace Ui {
    class GameLItem;
}

class GameLItem : public QFrame
{
    Q_OBJECT

public:
    explicit GameLItem(QWidget *parent = 0);
    explicit GameLItem(DataModel *model,QWidget *parent = 0);
    ~GameLItem();
signals:

    void delGameSI(const int &id);
    void showGameSI(const int &id);
    void upInfoGameSI(const int &id);
    void upPackGameSI(const int &id);
    void buildInitGameSI(const int &id);
    void syncGameSI(const int &id);
public slots:
    void updateUi();
private slots:

    void delGame();
    void showGame();
    void upInfoGame();
    void upPackGame();
    void buildInitGame();
    void syncGameSL();

private:
    Ui::GameLItem *ui;
    DataModel *model;
    QAction *info;
    QAction *updateInfo;
    QAction *updatePack;
    QAction *buildInit;
    QAction *syncGame;
    QAction *del;
};

#endif // GAMELITEM_H
